package com.hg.design.behavior.observer.biancheng.ex4;

import java.util.Observable;
import java.util.Observer;

public class CrudeOilFutures {
    public static void main(String[] args) {
        OilFutures oilFutures = new OilFutures();
        Observer bull = new Bull();
        Observer bear = new Bear();
        oilFutures.addObserver(bull);
        oilFutures.addObserver(bear);
        oilFutures.setPrice(10.0f);
        oilFutures.setPrice(-8.0f);
    }
}
